package lab.poc.erl.otp;

public class ChildSpec {

	public static enum RestartType {
		/**
		 * Transient processes are never restarted.
		 */
		TRANSIENT,
		/**
		 * Temporary processes are only restarted if they terminate abnormally.
		 */
		TEMPORARY,
		/**
		 * Permanent processes are always restarted regardless of the
		 * termination reason.
		 */
		PERMANENT
	}

	public final String id;
	public final StartSpec startSpec;
	public final RestartType restart;
	public final ProcessType type;

	public ChildSpec(final String id, final StartSpec spec,
			final RestartType restart, final ProcessType type) {
		this.id = id;
		this.startSpec = spec;
		this.restart = restart;
		this.type = type;
	}
}
